package com.viptail.xiaogouzaijia.view.activyty;

import android.support.annotation.NonNull;
import android.view.View;
import android.widget.Button;
import android.widget.LinearLayout;
import android.widget.TextView;

import com.viptail.xiaogouzaijia.R;
import com.viptail.xiaogouzaijia.api.ExceptionHandle;
import com.viptail.xiaogouzaijia.bean.special.SpecialBean;
import com.viptail.xiaogouzaijia.presenter.TestPresenter;
import com.viptail.xiaogouzaijia.presenter.base.BaseRetrofitPresenter;
import com.viptail.xiaogouzaijia.view.base.BaseActivity;

import butterknife.BindView;
import butterknife.OnClick;

/**
 * Created by FROG on 2016/11/10.
 */

public class TestActivity extends BaseActivity<SpecialBean> {

    @BindView(R.id.tv)
    TextView tv;
    @BindView(R.id.btn)
    Button btn;
    @BindView(R.id.activity_test_mvp)
    LinearLayout activityTestMvp;

    @Override
    public int getContentId() {
        return R.layout.activity_test_mvp;
    }

    @Override
    public void initView() {

    }

    @Override
    public void initData() {
//        ((TestPresenter) presenter).getSpecialData();
    }

    @OnClick(R.id.btn)
    public void click(View v){
        tv.setText("试验成功");
    }


    @NonNull
    @Override
    public BaseRetrofitPresenter<SpecialBean> createPresenter() {
        return new TestPresenter();
    }

    @Override
    public void onSuccess(SpecialBean s) {

    }

    @Override
    public void onFinish() {

    }

    @Override
    public void onFail(ExceptionHandle.ResponeThrowable e) {

    }
}
